package com.hello.system.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.hello.common.core.annotation.Excel;
import com.hello.common.core.web.domain.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 好友申请请求对象 friend_requests
 * 
 * @author hello
 * @date 2025-10-29
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class FriendRequests extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 请求ID（主键） */
    private Long requestId;

    /** 发送者用户ID（关联users表） */
    @Excel(name = "发送者用户ID", readConverterExp = "关=联users表")
    private Long senderId;

    /** 接收者用户ID（关联users表） */
    @Excel(name = "接收者用户ID", readConverterExp = "关=联users表")
    private Long receiverId;

    /** 请求状态（0-已拒绝，1-待处理，2-已同意，3-已过期） */
    @Excel(name = "请求状态", readConverterExp = "0=-已拒绝，1-待处理，2-已同意，3-已过期")
    private Integer status;

    /** 申请附加消息/验证信息 */
    @Excel(name = "申请附加消息/验证信息")
    private String message;

    /** 添加来源（如搜索、推荐、扫码、附近的人等） */
    @Excel(name = "添加来源", readConverterExp = "如=搜索、推荐、扫码、附近的人等")
    private String source;

    /** 请求创建时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "请求创建时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date createdAt;

    /** 请求过期时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "请求过期时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date expiredAt;

    /** 请求处理时间（同意或拒绝的时间） */
    @Excel(name = "请求处理时间", readConverterExp = "同=意或拒绝的时间")
    private Date processedAt;

    /** 更新时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date updatedAt;

    public void setRequestId(Long requestId) 
    {
        this.requestId = requestId;
    }

    public Long getRequestId() 
    {
        return requestId;
    }
    public void setSenderId(Long senderId) 
    {
        this.senderId = senderId;
    }

    public Long getSenderId() 
    {
        return senderId;
    }
    public void setReceiverId(Long receiverId) 
    {
        this.receiverId = receiverId;
    }

    public Long getReceiverId() 
    {
        return receiverId;
    }
    public void setStatus(Integer status) 
    {
        this.status = status;
    }

    public Integer getStatus() 
    {
        return status;
    }
    public void setMessage(String message) 
    {
        this.message = message;
    }

    public String getMessage() 
    {
        return message;
    }
    public void setSource(String source) 
    {
        this.source = source;
    }

    public String getSource() 
    {
        return source;
    }
    public void setCreatedAt(Date createdAt) 
    {
        this.createdAt = createdAt;
    }

    public Date getCreatedAt() 
    {
        return createdAt;
    }
    public void setExpiredAt(Date expiredAt) 
    {
        this.expiredAt = expiredAt;
    }

    public Date getExpiredAt() 
    {
        return expiredAt;
    }
    public void setProcessedAt(Date processedAt) 
    {
        this.processedAt = processedAt;
    }

    public Date getProcessedAt() 
    {
        return processedAt;
    }
    public void setUpdatedAt(Date updatedAt) 
    {
        this.updatedAt = updatedAt;
    }

    public Date getUpdatedAt() 
    {
        return updatedAt;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("requestId", getRequestId())
            .append("senderId", getSenderId())
            .append("receiverId", getReceiverId())
            .append("status", getStatus())
            .append("message", getMessage())
            .append("source", getSource())
            .append("createdAt", getCreatedAt())
            .append("expiredAt", getExpiredAt())
            .append("processedAt", getProcessedAt())
            .append("updatedAt", getUpdatedAt())
            .toString();
    }
}
